/**
 * Copyright (c) 2011-2014, hubin (jobob@qq.com).
 *
 * Licensed under the Apache License, Version 2.0 (the "License"); you may not
 * use this file except in compliance with the License. You may obtain a copy of
 * the License at
 *
 * http://www.apache.org/licenses/LICENSE-2.0
 *
 * Unless required by applicable law or agreed to in writing, software
 * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
 * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
 * License for the specific language governing permissions and limitations under
 * the License.
 */
package com.baomidou.jas.controller.system;

import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.ResponseBody;

import com.baomidou.jas.controller.BaseController;

/**
 * <p>
 * 权限管理
 * </p>
 * 
 * @author hubin
 * @Date 2016-02-15
 */
@Controller
@RequestMapping("/system/permission")
public class SysPermissionController extends BaseController {


	/**
	 * 当前用户 JSON 格式权限列表
	 */
	@ResponseBody
	@RequestMapping("/json")
	public String json() {
		return "[{\"id\":28,\"pid\":2,\"name\":\"查看\",\"type\":\"O\",\"sort\":null,\"url\":\"\",\"icon\":\"\",\"permCode\":\"sys:role:view\",\"description\":\"角色查看\",\"state\":\"\"},{\"id\":30,\"pid\":12,\"name\":\"查看\",\"type\":\"O\",\"sort\":null,\"url\":\"\",\"icon\":\"\",\"permCode\":\"sys:perm:view\",\"description\":\"权限查看\",\"state\":null},{\"id\":31,\"pid\":20,\"name\":\"删除\",\"type\":\"O\",\"sort\":null,\"url\":\"\",\"icon\":\"\",\"permCode\":\"sys:log:delete\",\"description\":\"删除日志\",\"state\":null},{\"id\":33,\"pid\":3,\"name\":\"查看用户角色\",\"type\":\"O\",\"sort\":null,\"url\":\"\",\"icon\":\"\",\"permCode\":\"sys:user:roleView\",\"description\":\"查看用户角色\",\"state\":null},{\"id\":36,\"pid\":2,\"name\":\"查看角色权限\",\"type\":\"O\",\"sort\":null,\"url\":\"\",\"icon\":\"\",\"permCode\":\"sys:role:permView\",\"description\":\"查看角色拥有的权限\",\"state\":null},{\"id\":35,\"pid\":3,\"name\":\"修改用户角色\",\"type\":\"O\",\"sort\":null,\"url\":\"\",\"icon\":\"\",\"permCode\":\"sys:user:roleUpd\",\"description\":\"修改用户拥有的角色\",\"state\":null},{\"id\":34,\"pid\":2,\"name\":\"保存授权\",\"type\":\"O\",\"sort\":null,\"url\":\"\",\"icon\":\"\",\"permCode\":\"sys:role:permUpd\",\"description\":\"保存修改的角色权限\",\"state\":null},{\"id\":32,\"pid\":20,\"name\":\"导出excel\",\"type\":\"O\",\"sort\":null,\"url\":\"\",\"icon\":\"\",\"permCode\":\"sys:log:exportExcel\",\"description\":\"导出日志excel\",\"state\":null},{\"id\":37,\"pid\":15,\"name\":\"定时任务管理\",\"type\":\"F\",\"sort\":null,\"url\":\"system/scheduleJob\",\"icon\":\"icon-hamburg-full-time\",\"permCode\":\"\",\"description\":\"定时任务管理，支持集群\",\"state\":null},{\"id\":38,\"pid\":15,\"name\":\"cron表达式生成\",\"type\":\"F\",\"sort\":null,\"url\":\"system/scheduleJob/quartzCron\",\"icon\":\"icon-hamburg-future\",\"permCode\":\"\",\"description\":\"\",\"state\":null},{\"id\":29,\"pid\":3,\"name\":\"查看\",\"type\":\"O\",\"sort\":null,\"url\":\"\",\"icon\":\"\",\"permCode\":\"sys:user:view\",\"description\":\"用户查看\",\"state\":null},{\"id\":61,\"pid\":40,\"name\":\"添加\",\"type\":\"O\",\"sort\":null,\"url\":\"\",\"icon\":null,\"permCode\":\"sys:dict:add\",\"description\":\"字典管理\",\"state\":null},{\"id\":62,\"pid\":40,\"name\":\"删除\",\"type\":\"O\",\"sort\":null,\"url\":\"\",\"icon\":null,\"permCode\":\"sys:dict:delete\",\"description\":\"字典管理\",\"state\":null},{\"id\":63,\"pid\":40,\"name\":\"修改\",\"type\":\"O\",\"sort\":null,\"url\":\"\",\"icon\":null,\"permCode\":\"sys:dict:update\",\"description\":\"字典管理\",\"state\":null},{\"id\":58,\"pid\":39,\"name\":\"添加\",\"type\":\"O\",\"sort\":null,\"url\":\"\",\"icon\":null,\"permCode\":\"sys:perm:add\",\"description\":\"菜单管理\",\"state\":null},{\"id\":59,\"pid\":39,\"name\":\"删除\",\"type\":\"O\",\"sort\":null,\"url\":\"\",\"icon\":null,\"permCode\":\"sys:perm:delte\",\"description\":\"菜单管理\",\"state\":null},{\"id\":4,\"pid\":2,\"name\":\"添加\",\"type\":\"O\",\"sort\":null,\"url\":\"\",\"icon\":\"\",\"permCode\":\"sys:role:add\",\"description\":\"角色添加\",\"state\":\"\"},{\"id\":6,\"pid\":2,\"name\":\"修改\",\"type\":\"O\",\"sort\":null,\"url\":\"\",\"icon\":\"\",\"permCode\":\"sys:role:update\",\"description\":\"角色修改\",\"state\":\"\"},{\"id\":26,\"pid\":12,\"name\":\"修改\",\"type\":\"O\",\"sort\":null,\"url\":\"\",\"icon\":\"\",\"permCode\":\"sys:perm:update\",\"description\":\"菜单修改\",\"state\":\"\"},{\"id\":27,\"pid\":12,\"name\":\"删除\",\"type\":\"O\",\"sort\":null,\"url\":\"\",\"icon\":\"\",\"permCode\":\"sys:perm:delete\",\"description\":\"菜单删除\",\"state\":\"\"},{\"id\":5,\"pid\":2,\"name\":\"删除\",\"type\":\"O\",\"sort\":null,\"url\":\"\",\"icon\":\"\",\"permCode\":\"sys:role:delete\",\"description\":\"角色删除\",\"state\":\"\"},{\"id\":25,\"pid\":12,\"name\":\"添加\",\"type\":\"O\",\"sort\":null,\"url\":\"\",\"icon\":\"\",\"permCode\":\"sys:perm:add\",\"description\":\"菜单添加\",\"state\":\"\"},{\"id\":45,\"pid\":39,\"name\":\"修改\",\"type\":\"O\",\"sort\":null,\"url\":\"\",\"icon\":null,\"permCode\":\"sys:perm:update\",\"description\":\"菜单管理\",\"state\":null},{\"id\":7,\"pid\":3,\"name\":\"添加\",\"type\":\"O\",\"sort\":null,\"url\":\"\",\"icon\":\"\",\"permCode\":\"sys:user:add\",\"description\":\"用户添加\",\"state\":\"\"},{\"id\":8,\"pid\":3,\"name\":\"删除\",\"type\":\"O\",\"sort\":null,\"url\":\"\",\"icon\":\"\",\"permCode\":\"sys:user:delete\",\"description\":\"用户删除\",\"state\":\"\"},{\"id\":16,\"pid\":3,\"name\":\"修改\",\"type\":\"O\",\"sort\":null,\"url\":\"\",\"icon\":\"\",\"permCode\":\"sys:user:update\",\"description\":\"用户修改\",\"state\":\"\"},{\"id\":69,\"pid\":40,\"name\":\"查看\",\"type\":\"O\",\"sort\":null,\"url\":\"\",\"icon\":null,\"permCode\":\"sys:dict:view\",\"description\":\"字典管理\",\"state\":null},{\"id\":70,\"pid\":39,\"name\":\"查看\",\"type\":\"O\",\"sort\":null,\"url\":\"\",\"icon\":null,\"permCode\":\"sys:perm:menu:view\",\"description\":\"菜单管理\",\"state\":null},{\"id\":68,\"pid\":20,\"name\":\"查看\",\"type\":\"O\",\"sort\":null,\"url\":\"\",\"icon\":null,\"permCode\":\"sys:log:view\",\"description\":\"查看日志\",\"state\":null},{\"id\":71,\"pid\":null,\"name\":\"商店管理\",\"type\":\"F\",\"sort\":null,\"url\":\"\",\"icon\":\"icon-hamburg-basket\",\"permCode\":null,\"description\":\"商店\",\"state\":null},{\"id\":72,\"pid\":71,\"name\":\"商品管理\",\"type\":\"F\",\"sort\":null,\"url\":\"shop/goods\",\"icon\":\"icon-hamburg-product\",\"permCode\":null,\"description\":\"商品管理\",\"state\":null},{\"id\":73,\"pid\":71,\"name\":\"商品类型管理\",\"type\":\"F\",\"sort\":null,\"url\":\"shop/goodsType\",\"icon\":\"icon-hamburg-milestone\",\"permCode\":null,\"description\":\"商品类型\",\"state\":null},{\"id\":76,\"pid\":3,\"name\":\"查看用户机构\",\"type\":\"O\",\"sort\":null,\"url\":\"\",\"icon\":null,\"permCode\":\"sys:user:orgView\",\"description\":\"查看用户机构\",\"state\":null},{\"id\":77,\"pid\":3,\"name\":\"修改用户机构\",\"type\":\"O\",\"sort\":null,\"url\":\"\",\"icon\":null,\"permCode\":\"sys:user:orgUpd\",\"description\":\"修改用户所在的机构\",\"state\":null},{\"id\":1,\"pid\":null,\"name\":\"系统管理\",\"type\":\"F\",\"sort\":1,\"url\":\"\",\"icon\":\"icon-standard-cog\",\"permCode\":\"\",\"description\":\"\",\"state\":\"\"},{\"id\":3,\"pid\":1,\"name\":\"用户管理\",\"type\":\"F\",\"sort\":2,\"url\":\"system/user\",\"icon\":\"icon-hamburg-user\",\"permCode\":\"\",\"description\":\"\",\"state\":\"closed\"},{\"id\":2,\"pid\":1,\"name\":\"角色管理\",\"type\":\"F\",\"sort\":3,\"url\":\"system/role\",\"icon\":\"icon-hamburg-my-account\",\"permCode\":\"\",\"description\":\"\",\"state\":\"closed\"},{\"id\":39,\"pid\":1,\"name\":\"菜单管理\",\"type\":\"F\",\"sort\":4,\"url\":\"system/permission/menu\",\"icon\":\"icon-hamburg-old-versions\",\"permCode\":\"\",\"description\":\"\",\"state\":null},{\"id\":12,\"pid\":1,\"name\":\"权限管理\",\"type\":\"F\",\"sort\":5,\"url\":\"system/permission\",\"icon\":\"icon-hamburg-login\",\"permCode\":\"\",\"description\":\"\",\"state\":\"closed\"},{\"id\":15,\"pid\":null,\"name\":\"系统监控\",\"type\":\"F\",\"sort\":5,\"url\":\"\",\"icon\":\"icon-hamburg-graphic\",\"permCode\":\"\",\"description\":\"\",\"state\":\"\"},{\"id\":14,\"pid\":15,\"name\":\"数据源监控\",\"type\":\"F\",\"sort\":6,\"url\":\"druid\",\"icon\":\"icon-hamburg-database\",\"permCode\":\"\",\"description\":\"\",\"state\":\"\"},{\"id\":40,\"pid\":1,\"name\":\"字典管理\",\"type\":\"F\",\"sort\":6,\"url\":\"system/dict\",\"icon\":\"icon-hamburg-address\",\"permCode\":null,\"description\":\"数据字典管理\",\"state\":null},{\"id\":20,\"pid\":15,\"name\":\"日志管理\",\"type\":\"F\",\"sort\":7,\"url\":\"system/log\",\"icon\":\"icon-hamburg-archives\",\"permCode\":\"\",\"description\":\"\",\"state\":\"\"},{\"id\":74,\"pid\":1,\"name\":\"区域信息\",\"type\":\"F\",\"sort\":7,\"url\":\"system/area\",\"icon\":\"icon-hamburg-world\",\"permCode\":null,\"description\":\"管理行政区划\",\"state\":null},{\"id\":75,\"pid\":1,\"name\":\"机构管理\",\"type\":\"F\",\"sort\":8,\"url\":\"system/organization\",\"icon\":\"icon-cologne-home\",\"permCode\":null,\"description\":\"组织机构管理\",\"state\":null}]";
	}
}
